<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class AddFollowsTable extends Migration {

	/**
	 * Run the migrations.
	 *
	 * @return void
	 */
	public function up()
	{
		// 关注
		Schema::create('follows', function(Blueprint $table){
			$table->increments('id');
			$table->integer('user_id');				// 发起关注动作的用户的id
			$table->integer('follow_id');			// 被关注的用户的id
			$table->tinyInteger('follow_stat');		// 关注的状态
			$table->timestamps();
		});
	}

	/**
	 * Reverse the migrations.
	 *
	 * @return void
	 */
	public function down()
	{
		Schema::drop('follows');
	}

}
